/* OnlineList */

$(document).ready(function(){init();});

function init(){
    // Do some initialization work.
}

function toggle_details(ndsgame_id) {
    var s = $("#ndsgame"+ndsgame_id).text();
    var l = s.length;
    if (l==0) {
        $.post("/"+ndsgame_id+"/", {},
            function(data){
                //alert("Data Loaded: " + data);
                data = '<div id="ndsgame'+ndsgame_id+'">'+data+'</div>';
                $("#ndsgame"+ndsgame_id).replaceWith(data);
            });
    } else {
        $("#ndsgame"+ndsgame_id).toggle();
    }
}
